import requestInstance from '../utils/http.js'

/**
 * @description  请求首页的数据
 * @returns {Array<{code:number,data:Array<{ createTime: string, 
 *	id:number,
 *	imageUrl:string,
 *	isDeleted:number,
 *	linkUrl:string,
 *	sort:number,
 *	title:string,
 *	updateTime: string,
 *}>,message:string}>}
 *
 */
export const reqIndexData = () =>{
	// Promise.all([
	// 	requestInstance.get('/index/findBanner',{},{}),
	// 	requestInstance.get('/index/findCategory1',{},{}),
	// 	requestInstance.get('/index/advertisement',{},{}),
	// 	requestInstance.get('/index/findListGoods',{},{}),
	// 	requestInstance.get('/index/findRecommendGoods',{},{}),	
	// ])
	
	return requestInstance.all(
		requestInstance.get('/index/findBanner',{},{}),
		requestInstance.get('/index/findCategory1',{},{}),
		requestInstance.get('/index/advertisement',{},{}),
		requestInstance.get('/index/findListGoods',{},{}),
		requestInstance.get('/index/findRecommendGoods',{},{}),	
	)
}
/**
 * 
 * 
 * 
 * 
 * 
 */